<%@ page contentType="text/html;charset=UTF-8" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %>
<!DOCTYPE html>
<html>

<head>
    <title>
       问卷详情
    </title>
    <link href="${ctx}/static/inspinia/js/plugins/iCheck/dcwj.css" rel="stylesheet">
</head>
<body>
    <div id="wrapper">
        <div class="gray-bg p-sm">
            <div class="row">
                <div class="col-lg-12">
                   <div class="dcwj white-bg">
                       <div class="dcwj-content p-md">
                           <div class="dcwj-content-title m-b-md">单位健康促进调查问卷</div>
                           <h2 class="m-b-md text-font-size">一&nbsp;基本信息</h2>
                           <div class="dcwj-select-item">
                               <h3>1&nbsp;性别:</h3>
                               <div class="m">
                                   <span class="file-box">
                                       <label class="i-checks">
                                           <input type="radio" id="sex1" name="sex" <c:if test="${question.sex == 0}">checked="true"</c:if> value="1"> <i></i> 男 </label>
                                   </span>
                                   <span class="i-checks">
                                       <label>
                                           <input type="radio" id="sex2" name="sex" <c:if test="${question.sex == 1}">checked="true"</c:if> value="2"> <i></i> 女 </label>
                                   </span>
                               </div>
                           </div>
                           <div class="dcwj-select-item m-t">
                               <h3>2&nbsp;年龄:</h3>
                               <div class="m">
                                   <span class="i-checks m-r-xl">
                                       <label>
                                           <input type="radio"   value="1" name="age" <c:if test="${question.age == 0}">checked="true"</c:if> id="age1"> <i></i> 18-25岁 </label>
                                   </span>
                                   <span class="i-checks m-r-xl">
                                       <label>
                                           <input type="radio"   value="1" name="age" <c:if test="${question.age == 1}">checked="true"</c:if> id="age2"> <i></i> 26-34岁 </label>
                                   </span>
                                   <span class="i-checks m-r-xl">
                                       <label>
                                           <input type="radio" value="2" name="age"<c:if test="${question.age == 2}">checked="true"</c:if> id="age3"> <i></i> 35-45岁 </label>
                                   </span>
                                    <span class="i-checks m-r">
                                       <label>
                                           <input type="radio" value="3" name="age" <c:if test="${question.age == 3}">checked="true"</c:if>id="age4"> <i></i> 46-55岁 </label>
                                   </span>
                                    <span class="i-checks m-r">
                                       <label>
                                           <input type="radio" value="4" name="age"<c:if test="${question.age == 4}">checked="true"</c:if> id="age5"> <i></i> >55岁 </label>
                                   </span>
                               </div>

                           </div>
                           <div class="dcwj-select-item m-t">
                               <h3>3&nbsp;身高:&nbsp;厘米</h3>
                               <div class="m">
                                   <textarea rows="1" cols="50" id="height">${question.height}</textarea>
                               </div>

                           </div>
                           <div class="dcwj-select-item m-t">
                               <h3>4&nbsp;体重:&nbsp;公斤</h3>
                               <div class="m">
                                   <textarea rows="1" cols="50" id="weight">${question.weight}</textarea>
                               </div>

                           </div>
                           <h2 class="m-b-md text-font-size">二&nbsp;个人现状</h2>
                           <div class="dcwj-select-item m-t">
                               <h3>1&nbsp;请在下列符合您现状的选项上打勾:（可多选）</h3>
                               <div class="m">
                                   <div >
                                        <span class="file-box">
                                       <label class="i-checks">
                                           <input type="checkbox" id="qx0" value="1"> <i></i> 缺乏运动 </label>
                                   </span>
                                   <span class="file-box">
                                       <label class="i-checks">
                                           <input type="checkbox" id="qx1" value="2" > <i></i> 熬夜 </label>
                                   </span>
                                   <span >
                                       <label class="i-checks">
                                           <input type="checkbox" id="qx2" value="3" > <i></i> 吸烟 </label>
                                   </span>
                                   </div >
                                  <div class="m-t">
                                       <span class="file-box">
                                       <label class="i-checks">
                                           <input type="checkbox" id="qx3" value="4" > <i></i> 饮酒 </label>
                                   </span>
                                   <span class="file-box">
                                       <label class="i-checks">
                                           <input type="checkbox" id="qx4" value="5" > <i></i> 口味偏咸 </label>
                                   </span>
                                   <span >
                                       <label class="i-checks">
                                           <input type="checkbox" id="qx5" value="6" > <i></i> 肥胖 </label>
                                   </span>
                                  </div>

                               </div>
                           </div>
                           <div class="dcwj-select-item m-t">
                           <h3>2&nbsp;您经常参加体育锻炼吗&nbsp;?</h3>
                           <div class="m">
                                   <span class="i-checks m-r-xl">
                                       <label>
                                           <input type="radio" value="option7" <c:if test="${question.dl == 0}">checked="true"</c:if> name="c"> <i></i> 每天锻炼 </label>
                                   </span>
                                   <span class="i-checks m-r-xl">
                                       <label>
                                           <input type="radio"  value="option2" <c:if test="${question.dl == 1}">checked="true"</c:if>name="c"> <i></i> 每周锻炼3-5天 </label>
                                   </span>
                                    <span class="i-checks m-r">
                                       <label>
                                           <input type="radio" value="option8" <c:if test="${question.dl == 2}">checked="true"</c:if>name="c"> <i></i> 偶尔锻炼 </label>
                                   </span>
                                    <span class="i-checks m-r">
                                       <label>
                                           <input type="radio" value="option9" <c:if test="${question.dl == 3}">checked="true"</c:if>name="c"> <i></i> 从不锻炼 </label>
                                   </span>
                           </div>

                       </div>
                           <div class="dcwj-select-item m-t">
                               <h3>3&nbsp;您认为您目前的身体状况是&nbsp;:</h3>
                               <div class="m">
                                   <span class="i-checks m-r-xl">
                                       <label>
                                           <input type="radio" value="option10" <c:if test="${question.stzk == 0}">checked="true"</c:if>name="d"> <i></i>健康 </label>
                                   </span>
                                   <span class="i-checks m-r-xl">
                                       <label>
                                           <input type="radio"  value="option11" <c:if test="${question.stzk == 1}">checked="true"</c:if> name="d"> <i></i> 亚健康  </label>
                                   </span>
                                    <span class="i-checks m-r">
                                       <label>
                                           <input type="radio" value="option12"<c:if test="${question.stzk == 2}">checked="true"</c:if> name="d"> <i></i> 怀疑患病 </label>
                                   </span>
                                    <span class="i-checks m-r">
                                       <label>
                                           <input type="radio" value="option13" <c:if test="${question.stzk == 3}">checked="true"</c:if>name="d"> <i></i> 患病 </label>
                                   </span>
                               </div>

                           </div>
                           <h2 class="m-b-md text-font-size">三&nbsp;健康企业创建意见与建议</h2>
                           <div class="dcwj-select-item m-t">
                               <h3>1&nbsp;您喜欢的健康促进方式有:（可多选）</h3>
                               <div class="m">
                                   <div>
                                       <span class="i-checks file-box">
                                           <label>
                                               <input type="checkbox" id="jkcj0" value=""> <i></i> 健康讲座 </label>
                                       </span>
                                       <span class="i-checks file-box">
                                           <label>
                                               <input type="checkbox" id="jkcj1" value="" > <i></i> 义诊咨询 </label>
                                       </span>
                                       <span class="i-checks file-box">
                                           <label>
                                               <input type="checkbox" id="jkcj2" value="" > <i></i> 健康教育折页 </label>
                                       </span>
                                       <span >
                                           <label class="i-checks ">
                                               <input type="checkbox" id="jkcj3" value="" > <i></i> 版面巡展 </label>
                                       </span>
                                   </div>

                                   <div class="m-t">
                                       <span class="i-checks file-box ">
                                           <label>
                                               <input type="checkbox" id="jkcj4" value="" > <i></i> 流动健康驿站 </label>
                                       </span>
                                       <span class="i-checks file-box">
                                           <label>
                                               <input type="checkbox" id="jkcj5" value="" > <i></i> 健康评比  </label>
                                       </span>
                                       <span class="i-checks file-box">
                                           <label>
                                               <input type="checkbox" id="jkcj6" value="" > <i></i> 微信发布  </label>
                                       </span>
                                       <div >
                                           <label class="i-checks">
                                               <input type="checkbox" id="jkcj7" value="" > <i></i> 其他  </label>
                                       </div>
                                   </div>

                               </div>

                           </div>
                           <div class="dcwj-select-item m-t">
                               <h3>2&nbsp;您最希望了解哪些知识&nbsp;?（可多选）</h3>
                               <div class="m">
                                   <div>
                                       <span class="i-checks file-box">
                                           <label>
                                               <input type="checkbox" id="ljzs0" value=""> <i></i> 职业安全 </label>
                                       </span>
                                       <span class="i-checks file-box">
                                           <label>
                                               <input type="checkbox" id="ljzs1" value="" > <i></i> 疾病治疗 </label>
                                       </span>
                                       <span class="i-checks file-box">
                                           <label>
                                               <input type="checkbox" id="ljzs2" value="" > <i></i> 健康饮食 </label>
                                       </span>
                                       <span >
                                           <label class="i-checks ">
                                               <input type="checkbox" id="ljzs3" value="" > <i></i> 用药知识 </label>
                                       </span>
                                   </div>

                                   <div class="m-t">
                                       <span class="i-checks file-box ">
                                           <label>
                                               <input type="checkbox" id="ljzs4" value="" > <i></i> 健康运动 </label>
                                       </span>
                                       <span class="i-checks file-box">
                                           <label>
                                               <input type="checkbox" id="ljzs5" value="" > <i></i> 妇女儿童保健  </label>
                                       </span>
                                       <span class="i-checks file-box">
                                           <label>
                                               <input type="checkbox" id="ljzs6" value="" > <i></i> 中医养生  </label>
                                       </span>
                                       <div >
                                           <label class="i-checks">
                                               <input type="checkbox" id="ljzs7" value="" > <i></i> 心理咨询  </label>
                                       </div>
                                   </div>

                               </div>

                           </div>
                           <div class="dcwj-select-item m-t">
                               <h3>3&nbsp;您希望多久开展一次健康促进活动&nbsp;?</h3>
                               <div class="m">
                                   <span class="i-checks m-r-xl">
                                       <label>
                                           <input type="radio" value="option1" <c:if test="${question.jkzjhd == 0}">checked="true"</c:if> name="f"> <i></i> 一月1次 </label>
                                   </span>
                                   <span class="i-checks m-r-xl">
                                       <label>
                                           <input type="radio"  value="option2" <c:if test="${question.jkzjhd == 1}">checked="true"</c:if> name="f"> <i></i> 一季度1次  </label>
                                   </span>
                                    <span class="i-checks m-r">
                                       <label>
                                           <input type="radio" value="option3" <c:if test="${question.jkzjhd == 2}">checked="true"</c:if> name="f"> <i></i> 半年1次 </label>
                                   </span>
                                    <span class="i-checks m-r">
                                       <label>
                                           <input type="radio" value="option4" <c:if test="${question.jkzjhd == 3}">checked="true"</c:if> name="f"> <i></i> 其他   </label>
                                   </span>
                               </div>

                           </div>
                           <div class="dcwj-select-item m-t">
                               <h3>4&nbsp;您对单位现阶段开展的健康促进活动是否满意&nbsp;?</h3>
                               <div class="m">
                                   <span class="i-checks m-r-xl">
                                       <label>
                                           <input type="radio" value="option1" <c:if test="${question.sfmy == 0}">checked="true"</c:if> name="a"> <i></i> 非常满意 </label>
                                   </span>
                                   <span class="i-checks m-r-xl">
                                       <label>
                                           <input type="radio"  value="option2" <c:if test="${question.sfmy == 1}">checked="true"</c:if> name="a"> <i></i> 比较满意  </label>
                                   </span>
                                    <span class="i-checks m-r">
                                       <label>
                                           <input type="radio" value="option1" <c:if test="${question.sfmy == 2}">checked="true"</c:if> name="a"> <i></i> 不满意 </label>
                                   </span>
                               </div>

                           </div>
                           <div class="dcwj-select-item m-t">
                               <h3>5&nbsp;您对单位健康促进活动有什么意见和建议:</h3>
                               <div class="m">
                                   <textarea rows="1" cols="50" class="dcwj-form-control-border">${question.yj}</textarea>
                               </div>

                           </div>
                           <h3 class="m-t-md">谢谢您的支持和参与！</h3>
                           <div class="dcwj-content-submit">
                            <c:if test="${sys_flag}">
                               <input type="button" value="关闭" onclick="gbclose()">
                            </c:if>
                            <c:if test="${!sys_flag}">
                               <a href="javascript:history.go(-1);" class="btn btn-white ">返回</a>
                            </c:if>
                           </div>
                       </div>
                   </div>
                </div>
            </div>
        </div>
    </div>
    <%--<script src="js/jquery-2.1.1.js"></script>--%>
    <script src="${ctx}/static/inspinia/js/plugins/iCheck/icheck.min.js"></script>
    <script>
        $(document).ready(function() {
            $('.i-checks').iCheck({
                checkboxClass: 'icheckbox_square-green',
                radioClass: 'iradio_square-green'
            });

            var listone = ${list1};
            var listtwo =${list2};
            var listthree = ${list3};

            if(listone != undefined){
                for (var i = 0 ; i<listone.length ; i++){
                    $("input[id=qx"+listone[i]+"]").attr("checked", true);
                    $("input[id=qx"+listone[i]+"]").parent().addClass("checked");
                }
            }

            if(listtwo != undefined) {
                for (var i = 0 ; i<listtwo.length ; i++){
                    $("input[id=jkcj"+listtwo[i]+"]").attr("checked", true);
                    $("input[id=jkcj"+listtwo[i]+"]").parent().addClass("checked");
                }
            }
            if(listthree != undefined) {
                for (var i = 0 ; i<listthree.length ; i++){
                    $("input[id=ljzs"+listthree[i]+"]").attr("checked", true);
                    $("input[id=ljzs"+listthree[i]+"]").parent().addClass("checked");
                }
            }

        });

        function gbclose() {
            var index = parent.layer.getFrameIndex(window.name); //先得到当前iframe层的索引
            parent.layer.close(index); //再执行关闭
        }
    </script>
</body>

</html>
